package cn.tedu.shoppingmall.mapper;

import cn.tedu.shoppingmall.vo.AddCls;
import cn.tedu.shoppingmall.vo.Class;
import org.apache.ibatis.annotations.Insert;

import org.apache.ibatis.annotations.Select;
import org.mapstruct.Mapper;

import java.util.List;
//商品类数据库增删改查操作
@Mapper
public interface ClassMapper {

    //增加商品类
    @Insert("insert into class(name,url) values(#{name},#{url})")
    void addCls(AddCls cls);


    //搜索所有商品类的类信息
    @Select("select * from class")
    List<Class> select();

}
